package _1引入;

public class Employee {
	
	private String name;
	private int salary;
	Company companyBelong;
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public int getSalary() {
		return salary;
	}
	public void setSalary(int salary) {
		this.salary = salary;
	}
	public Company getCompanyBelong() {
		return companyBelong;
	}
	public void setCompanyBelong(Company companyBelong) {
		this.companyBelong = companyBelong;
	}
	
	@Override
	public String toString() {
		// TODO Auto-generated method stub
		if(companyBelong==null) {
			return ("当前已离职");
		}
		else {
			return ("我是"+this.companyBelong.getCompanyCEO()+"公司的,"+"我的薪水是:"+this.salary);
		}
	}

}
